<%@ taglib prefix="decorator"
	uri="http://www.opensymphony.com/sitemesh/decorator"%>
<%@ taglib prefix="spring" uri="http://www.springframework.org/tags"%>
<%@ taglib prefix="sec"
	uri="http://www.springframework.org/security/tags"%>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core"%>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" lang="en">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>Web App Theme</title>
<link rel="stylesheet" href="layout2/stylesheets/base.css" type="layout2/text/css"
	media="screen" />
<link rel="stylesheet" id="current-theme"
	href="layout2/stylesheets/themes/default/style.css" type="layout2/text/css"
	media="screen" />
<script type="layout2/text/javascript" charset="utf-8"
	src="layout2/javascripts/jquery-1.3.min.js"></script>
<script type="layout2/text/javascript" charset="utf-8"
	src="layout2/javascripts/jquery.scrollTo.js"></script>
<script type="layout2/text/javascript" charset="utf-8"
	src="layout2/javascripts/jquery.localscroll.js"></script>
<script type="layout2/text/javascript" charset="utf-8">
	//          
	var Theme = {
		activate : function(name) {
			window.location.hash = 'themes/' + name
			Theme.loadCurrent();
		},

		loadCurrent : function() {
			var hash = window.location.hash;
			if (hash.length > 0) {
				matches = hash.match(/^#themes\/([a-z0-9\-_]+)$/);
				if (matches && matches.length > 1) {
					$('#current-theme').attr('href',
							'stylesheets/themes/' + matches[1] + '/style.css');
				} else {
					alert('theme not valid');
				}
			}
		}
	}

	$(document)
			.ready(
					function() {
						Theme.loadCurrent();
						$.localScroll();
						$('.table :checkbox.toggle')
								.each(
										function(i, toggle) {
											$(toggle)
													.change(
															function(e) {
																$(toggle)
																		.parents(
																				'table:first')
																		.find(
																				':checkbox:not(.toggle)')
																		.each(
																				function(
																						j,
																						checkbox) {
																					checkbox.checked = !checkbox.checked;
																				})
															});
										});
					});
	//
</script>
</head>
<body>
	<div id="container">
		<div id="header">
			<h1>
				<a href="index.html">Web App Theme</a>
			</h1>
			<div id="user-navigation">
				<ul class="wat-cf">
					<li><a href="#">Profile</a>
					</li>
					<li><a href="#">Settings</a>
					</li>
					<li><a class="logout" href="#">Logout</a>
					</li>
				</ul>
			</div>
			<div id="main-navigation">
				<ul class="wat-cf">
					<li class="first"><a href="#block-text">Main Page</a>
					</li>
					<li class="active"><a href="#block-text">Active</a>
					</li>
					<li><a href="#block-login">Login</a>
					</li>
					<li><a href="#block-signup">Signup</a>
					</li>
				</ul>
			</div>
		</div>

		<div id="content">
			<decorator:body />
		</div>
	</div>
</body>
</html>

